package com.fenxiangtech.mall.dao;

import com.fenxiangtech.mall.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

/**
 * @author zhangjiashun
 */
@Mapper
@Repository
public interface UserDao {

    /**
     * 根据openid获取User
     * @param openid
     * @return
     */
    User getUserByOpenID(String openid);

    /**
     * 添加用户
     * @param user
     */
    int saveUser(User user);

    /**
     * 更新用户信息
     * @param user
     * @return
     */
    int updateUser(User user);

}
